#ifndef __QUMI_HUMIDITY_H
#define __QUMI_HUMIDITY_H

#include "stm8s.h"

extern uint8_t g_humi_threshold;

struct dewpoint_s
{
  uint8_t temp;
  uint8_t humi;
  uint8_t dewpoint;
};

struct dewpoint_threshold_s
{
  uint8_t temp;
  uint8_t min;
  uint8_t max;
};

struct humi_table_s
{
  uint8_t temp;
  uint16_t *tbl;
};


extern struct dewpoint_threshold_s g_dewpoint_thres_table[];

void Humidity_Init(void);
void Humidity_Task(void);
void Humidity_Start(FunctionalState state);

#endif
